package com.jzl.canal_consumer;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.ApplicationContext;

@SpringBootApplication(scanBasePackages = "com.jzl")
public class App
{
    private static ApplicationContext ctx;

    public static void main(String[] args)
    {
        ctx = SpringApplication.run(App.class, args);
        ConsumerStarter consumerStarter = ctx.getBean(ConsumerStarter.class);
        consumerStarter.start();
    }

    public static ApplicationContext getApplicationContext()
    {
        return ctx;
    }
}

